package org.zgr.controller;

import cn.dev33.satoken.annotation.SaIgnore;
import common.dtos.ResponseResult;
import common.entity.book.BookInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.zgr.service.BookService;

import java.util.List;

/**
 * @Author: 郑国荣
 * @Date: 2024-03-29-16:28
 * @Description:
 */
@RestController
@RequestMapping("/book")
public class BookController {
    @Autowired
    private BookService bookService;
    @SaIgnore
    @GetMapping("/get_books_list")
    public ResponseResult getGoodsList(){
        List<BookInfo> bookList = bookService.getBookList();
        return new ResponseResult<>(100, "成功", bookList);
    }
}
